package uestc.lj.gulishop.order.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;
import uestc.lj.common.utils.R;
import uestc.lj.gulishop.order.vo.WareSkuLockVO;

import java.util.List;

/**
 * @Author:Crazlee
 * @Date:2021/6/15
 */
@FeignClient("gulishop-ware")
public interface WareFeignService {
    @PostMapping("/ware/waresku/hasStock")
    public R getSkuHasStock(@RequestBody List<Long> skuIds);

    @GetMapping("/ware/wareinfo/fare")
    public R getFare(@RequestParam("addrId") Long addrId);

    @PostMapping("/ware/waresku/order/lock")
    public R lockStocks(@RequestBody WareSkuLockVO skuLockVO);
}
